package com.ld.common.webnotice.socket;

import com.corundumstudio.socketio.SocketIOClient;
import com.ld.common.webnotice.model.PushMessage;

public interface SocketIOService {

    // 推送的事件
    public static final String PUSH_EVENT = "push_event";

    // 启动服务
    void start() throws Exception;

    // 停止服务
    void stop();

    // 推送信息到个人
    void pushMessageToUser(PushMessage pushMessage);

    // 推送到具体的某个客户端
    public void pushMessageToUser(SocketIOClient client, PushMessage pushMessage);

    // 推送信息到群组
    void pushMessageToGroup(PushMessage pushMessage);

    // 推送信息到全体
    void pushMessageToAll(PushMessage pushMessage);

}